import numpy as np
from dezero.core import *
from dezero.functions_conv import conv2d_simple
#简单使用
N,C,H,W = 1,5,15,15
OC,(KH,KW) = 8,(3,3)

x=Variable(np.random.randn(N,C,H,W))
W = np.random.randn(OC,C,KH,KW)
y = conv2d_simple(x,W,b=None,stride=1,pad=1)
y.backward()

print(y.shape)
print(x.grad.shape)